#ifndef RETURNWINDOW_H
#define RETURNWINDOW_H

#include <QDialog>
#include <QLineEdit>
#include <QPushButton>
#include <QVBoxLayout>
#include <QHBoxLayout>
#include <QLabel>
#include <QMessageBox>
#include "database.h"

class ReturnWindow : public QDialog
{
    Q_OBJECT

public:
    explicit ReturnWindow(const QString &bookId, Database *db, QWidget *parent = nullptr);
    ~ReturnWindow();

private slots:
    void onReturnClicked();
    void onCancelClicked();

private:
    void setupUI();
    void createConnections();

    QString bookId;
    Database *db;
    QLineEdit *userIdEdit;
    QPushButton *returnButton;
    QPushButton *cancelButton;
};

#endif // RETURNWINDOW_H 
